package com.amtf.datafile3.core.std.render;

import com.amtf.datafile3.DataField;
import com.amtf.datafile3.DataFieldRender;
import com.amtf.datafile3.core.std.AbsDataFieldRender;
import com.amtf.datafile3.core.std.type.StringField;

public class StringFieldRender extends AbsDataFieldRender {

	public StringFieldRender() {
		super(null);
	}

	public String rending(DataField value) {
		String v = ((StringField) value).getValue();
		if (v != null) {
			return v;
		} else {
			return "";
		}
	}

	@Override
	public DataFieldRender clone() {
		StringFieldRender newObj = new StringFieldRender();
		return newObj;
	}
}
